var i;
Object.defineProperty(exports, "__esModule", {
  value: true
});
var EventManager = require("AA_EventManager");
var ResKeeper = require("AA_ResKeeper");
var EvenType = require("AA_EvenType");
var GuideControl = require("AA_GuideControl");
var _decorator = cc._decorator;
var _ccclass = _decorator.ccclass;
var _property = _decorator.property;
var _def_GuideShou = function (e) {
  function _creator() {
    var t = null !== e && e.apply(this, arguments) || this;
    t.shouNode = null;
    t.quanNode = null;
    return t;
  }
  __extends(_creator, e);
  _creator.prototype.StartSet = function (e) {
    var t = this;
    this.shouNode.stopAllActions();
    this.shouNode.children[0].active = true;
    this.shouNode.children[1].active = false;
    this.quanNode.stopAllActions();
    this.quanNode.active = false;
    if (e) {
      this.quanNode.active = true;
      this.quanNode.runAction(cc.repeatForever(cc.sequence(cc.callFunc(function () {
        t.quanNode.opacity = 255;
        t.quanNode.scale = 1;
      }), cc.spawn(cc.scaleTo(.5, 1.5, 1.5), cc.fadeOut(1)))));
      this.shouNode.runAction(cc.repeatForever(cc.sequence(cc.delayTime(.5), cc.callFunc(function () {
        t.shouNode.children[0].active = !t.shouNode.children[0].active;
        t.shouNode.children[1].active = !t.shouNode.children[0].active;
      }))));
    }
  };
  _creator.prototype.onEnable = function () {
    EventManager.EventMgr.addEventListener(EvenType.EVENT_TYPE.HideGuideShow, this.CloseThis, this);
  };
  _creator.prototype.onDisable = function () {
    EventManager.EventMgr.rmEventListener(EvenType.EVENT_TYPE.HideGuideShow, this.CloseThis, this);
  };
  _creator.prototype.CloseThis = function () {
    GuideControl.GuideCtrl.RecycleOneShou(this.node);
  };
  __decorate([_property(cc.Node)], _creator.prototype, "shouNode", undefined);
  __decorate([_property(cc.Node)], _creator.prototype, "quanNode", undefined);
  return __decorate([_ccclass], _creator);
}(ResKeeper.default);
exports.default = _def_GuideShou;